<template>
    <sk-article label="团队成员">
        <template #default>
            <div v-if="dataInfo.studentList.length">
                <el-table style="width: 100%" stripe lazy
                          :data="dataInfo.studentList" :row-key="row => row.id">
                    <el-table-column prop="name" label="姓名" width="auto"  ></el-table-column>
                    <el-table-column type="index" label="负责等级" width="120px"  >
                        <template #default="{$index}">
                            {{ $index === 0 ? "负责人" : "项目成员之一" }}
                        </template>
                    </el-table-column>
                    <el-table-column prop="school" label="所属院校" width="auto"  ></el-table-column>
                    <el-table-column prop="major" label="专业名称" width="auto"  ></el-table-column>
                    <el-table-column prop="academiclevel" label="学历层次" width="auto"  ></el-table-column>
                    <el-table-column width="auto" prop="telephone" label="联系电话"  ></el-table-column>
                    <el-table-column width="auto" prop="email" label="邮箱地址"  ></el-table-column>
                </el-table>
            </div>
            <el-empty v-else :image-size="200"/>
        </template>
    </sk-article>

    <sk-article label="指导教师">
        <template #default>
            <div v-if="dataInfo.instructorList.length">
                <el-table style="width: 100%" stripe lazy highlight-current-row
                          :data="dataInfo.instructorList" :row-key="row => row.id">
                    <el-table-column prop="name" label="姓名" width="auto"  ></el-table-column>
                    <el-table-column type="index" label="指导等级" width="120px"  >
                        <template #default="{$index}">
                            {{ $index === 0 ? "第一指导老师" : "第二指导老师" }}
                        </template>
                    </el-table-column>
                    <el-table-column prop="title" label="职称" width="auto"  ></el-table-column>
                    <el-table-column prop="school" label="所在院校" width="auto"  ></el-table-column>
                    <el-table-column prop="dept" label="所在部门" width="auto"  ></el-table-column>
                    <el-table-column prop="telephone" label="联系电话" width="auto"  ></el-table-column>
                    <el-table-column prop="email" label="邮箱地址" width="auto"  ></el-table-column>
                </el-table>
            </div>
            <el-empty v-else :image-size="200"/>
        </template>
    </sk-article>

</template>

<script setup>
import SkArticle from "@/components/SkArticle.vue";

defineProps(["dataInfo"])
</script>

<style scoped>

</style>